package pta;

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
        while (in.hasNextDouble()){
        	double i = 0;
        	double x = in.nextDouble();
        	double epsilon = 0.0001;
        	if(x<0) System.out.println(Double.NaN);
        	else{
        		for(;;i = i+epsilon){
        			if(x-Math.pow(i, 2)<epsilon||Math.pow(i,2)>=x) break;
        		}
        		System.out.printf("%.6f\n",i);		
        	}
        }

	}
	
}
